#include <stdio.h>

int main(void)
{
    int num;
    scanf("%d", &num);

    long fac = 1;
    for (int i = 1; i <= num; i++)
        fac *= i;

    printf("%ld\n", fac);

    return 0;
}


